<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<title>首页</title>
		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<link rel="stylesheet" href="${pageContext.request.contextPath}/theme/css/main.css" type="text/css"/>
		<link rel="stylesheet" href="${pageContext.request.contextPath}/theme/css/style_login.css" type="text/css"/>
		<script type="text/javascript" src="${pageContext.request.contextPath}/theme/js/jquery-1.6.js"></script>
	</head>
	<body>
		<div class="login_page">

			<div class="l_tmenu">
				<span id="syn_div"> 
				<a href="<s:url action='preRegister' namespace='/user'></s:url>">免费注册</a> | <a
					href="<s:url action='preLogin' namespace='/user'></s:url>">登录</a>
				</span> |
				<a href="<s:url action="index.action" namespace="/channel"></s:url>" target="_blank">货运网首页</a> |
				<a href="#" target="_blank">帮助</a>
			</div>
			<h1 class="at_cis">
				<a href="<s:url action="index.action" namespace="/channel"></s:url>" class="at_gohome" title="">货运网</a>
			</h1>
			<div class="denglu-full">
			  <div id="ad_login_left" class="denglu1">
			  <img src="${pageContext.request.contextPath}/theme/images/3d_2.jpg" width="200" height="240" border="0" class="mt15 ml15" />
			  <div id="nav_today"
					style="height: 25px; overflow: hidden; margin-top: 10px; font-size: 15px; color: #555; width: 300px;">
					<ul class="clearfix">
						<li class="tle">
							<strong>在这里，有超过<span class="orange1">10万</span>辆汽车为您服务</strong>
						</li>
					</ul>
				</div>
			  </div>
			    <div class="denglu2">
			    	<div class="denglu3"></div>
			    	<form id="login_box" name="login_box" class="basic" method="post" action="${pageContext.request.contextPath}/login" onsubmit="return checkLogin();">
			        <div class="denglu4">
			        	<div class="denglu7">会员登录</div>
			        	<div style="display:none" id="error_msg" class="error_msg"><s:property value="SPRING_SECURITY_LAST_EXCEPTION.message" escape="session"/></div>
			            <div class="denglu8">
			            	<label>账&nbsp; 号</label><input type="text" class="login-text" value="" id="j_username" name="j_username"/>
			            </div>
			            <div class="denglu9">
			            	<label>密&nbsp; 码</label><input type="password" class="login-text" value="" id="j_password" name="j_password"/>
			            </div>
			            <!-- 
			            <div style="" id="vcode" class="denglu9">
			            	<label>验证码</label><input type="text" size="35" style="width: 60px;" value="" name="randNum" id="randNum">
			            	<img height="20" width="60" id="img" src="/validataImage.do" style="width:120px;height:30px;"><a href="javascript:refreshCode();">换一张？</a>
			            </div> -->
			            <div class="denglu10">
			            	<span class="save-login">
			                	<input name="_spring_security_remember_me" type="checkbox" value="1" id="_spring_security_remember_me" ><label>记住密码</label>
			                	<span class="line">|</span>
			                	<label class="forget-pw"><a target="_blank" href="<s:url action="forgetPassword.action" namespace="/user"></s:url>">忘记密码？</a></label>
			                </span>
			            </div>
			            <div class="denglu11">
			            	<span class="button button-lorange">
								<input id="button_submit" type="submit" value="登录" class="button-text">
							</span>
			            	<span style="padding-left:20px;"><a href="<s:url action='preRegister' namespace='/user'></s:url>" target="_blank">免费注册</a></span>
			            </div>
			        </div>
			        </form>
			        <div class="denglu5"></div>
			        <div class="denglu6"></div>
			    </div>
			    <div class="clear"></div>
			</div>
			<div class="clear"></div>
			<div>
				<jsp:include page="/footer.jsp"></jsp:include>
			</div>
		</div>

		<script type="text/javascript">
		$(function(){
			if($("#error_msg").html() != "")
			{
				$("#error_msg").show();
			}
		});
	function checkLogin()
	{
		var userName = $.trim($("#j_username").val());
		var password = $("#j_password").val();
		
		if(userName == "")
		{
			$("#error_msg").html("请输入用户名");
			$("#error_msg").show();
			return false;
		}
		
		if(password == "")
		{
			$("#error_msg").html("请输入密码");
			$("#error_msg").show();
			return false;
		}
		$("#error_msg").hide();
		return true;
	}
	</script>
	</body>
</html>